package com.candy.testOfIO;

import java.io.*;

/**
 * @author donglin
 * @Title:
 * @类名: Test04
 * @date 2020/5/28
 */
public class Test04 {
    public static void main(String[] args) {
        try(
                BufferedReader is=new BufferedReader(
                        new InputStreamReader(System.in));
        ) {
            System.out.println("请输入一段话，输入esc结束");
            String str= is.readLine();

            while (!str.trim().equalsIgnoreCase("esc")){
                System.out.println("您输出的内容是："+str);
                System.out.println("请输入一段话，输入esc结束");
                str= is.readLine();

            }

        } catch (FileNotFoundException e) {
            e.printStackTrace();
        } catch (IOException e) {
            e.printStackTrace();
        }

    }
}
